using System;
using System.Data;
using System.Collections.Generic;
using System.ServiceModel;
using eTMS.DAO;
namespace eTMS.Services{
	/********************************BEGIN NewsServiceBase****************************************/
	///<summary>
	/// <para>Author: Auto generated class by CSharp Code Generator v2.0</para>
	/// <para>Date:28/09/2010 47:04:27</para>
	/// <para>Class Name: NewsServiceBase</para>
	/// <para>Description: </para>
	///</summary>

	
	public partial class NewsService : INewsService{


		#region Select functions
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectOne</para>
		/// <para>Input: New_ID</para>
		/// <para>Output: NewsEntity</para>
		///</summary>
		public NewsEntity SelectOne(int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectOne(New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAll</para>
		/// <para>Input: </para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAll(){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAll();
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDS</para>
		/// <para>Input: </para>
		/// <para>Output: DataSet</para>
		///</summary>
		public DataSet SelectAllDS(){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDS();
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAll</para>
		/// <para>Input: </para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAllFilter(string strFilter){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllFilter(strFilter);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDS</para>
		/// <para>Input: </para>
		/// <para>Output: DataSet</para>
		///</summary>
		public DataSet SelectAllDSFilter(string strFilter){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDSFilter(strFilter);
		}
		#endregion

		#region Insert functions
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: Save</para>
		/// <para>Input: NewsEntity</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool Save(NewsEntity o){
			NewsDAO dao = new NewsDAO();
			return dao.Save(o);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: Save</para>
		/// <para>Input: NewsEntity</para>
		/// <para>Output: NewsEntity</para>
		///</summary>
		public NewsEntity SaveRet(NewsEntity o){
			NewsDAO dao = new NewsDAO();
			dao.Save(o);
			return o;
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SaveList</para>
		/// <para>Input: List of NewsEntity</para>
		/// <para>Output: </para>
		///</summary>
		public void SaveList(List<NewsEntity> list){
			NewsDAO dao = new NewsDAO();
			dao.SaveList(list);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SaveListRet</para>
		/// <para>Input: List of NewsEntity</para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SaveListRet(List<NewsEntity> list){
			this.SaveList(list);
			return list;
		}
		#endregion

		#region Update functions
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: Update</para>
		/// <para>Input: NewsEntity</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool Update(NewsEntity o){
			NewsDAO dao = new NewsDAO();
			return dao.Update(o);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateList</para>
		/// <para>Input: List of NewsEntity</para>
		/// <para>Output: </para>
		///</summary>
		public void UpdateList(List<NewsEntity> list){
			NewsDAO dao = new NewsDAO();
			dao.UpdateList(list);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateTitle</para>
		/// <para>Input: NewTitle,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateTitle(string NewTitle,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateTitle(NewTitle,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateMainContent</para>
		/// <para>Input: NewMainContent,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateMainContent(string NewMainContent,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateMainContent(NewMainContent,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateContent</para>
		/// <para>Input: NewContent,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateContent(string NewContent,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateContent(NewContent,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateNewIndex</para>
		/// <para>Input: NewNewIndex,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateNewIndex(int NewNewIndex,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateNewIndex(NewNewIndex,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateDatePost</para>
		/// <para>Input: NewDatePost,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateDatePost(DateTime NewDatePost,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateDatePost(NewDatePost,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateStatus</para>
		/// <para>Input: NewStatus,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateStatus(Byte NewStatus,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateStatus(NewStatus,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateDisplay</para>
		/// <para>Input: NewDisplay,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateDisplay(bool NewDisplay,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateDisplay(NewDisplay,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateIsHomePage</para>
		/// <para>Input: NewIsHomePage,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateIsHomePage(bool NewIsHomePage,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateIsHomePage(NewIsHomePage,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateDateAproved</para>
		/// <para>Input: NewDateAproved,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateDateAproved(DateTime NewDateAproved,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateDateAproved(NewDateAproved,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateDateExprired</para>
		/// <para>Input: NewDateExprired,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateDateExprired(DateTime NewDateExprired,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateDateExprired(NewDateExprired,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateCategory_ID</para>
		/// <para>Input: NewCategory_ID,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateCategory_ID(int NewCategory_ID,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateCategory_ID(NewCategory_ID,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateUser_ID</para>
		/// <para>Input: NewUser_ID,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateUser_ID(int NewUser_ID,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateUser_ID(NewUser_ID,New_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: UpdateApproved_ID</para>
		/// <para>Input: NewApproved_ID,New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool UpdateApproved_ID(int NewApproved_ID,int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.UpdateApproved_ID(NewApproved_ID,New_ID);
		}
		#endregion

		#region Delete functions
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: Delete</para>
		/// <para>Input: NewsEntity</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool Delete(NewsEntity o){
			NewsDAO dao = new NewsDAO();
			return dao.Delete(o);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: DeleteByID</para>
		/// <para>Input: New_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool DeleteByID(int New_ID){
			NewsDAO dao = new NewsDAO();
			return dao.DeleteByID(New_ID);
		}
		#endregion

		#region Select join to CategoriesUsers functions
		#endregion

		#region Select join to Categories functions
		#endregion

		#region Select join to Users functions
		#endregion

		#region Select,delete by New_ID functions
		#endregion

		#region Select,delete by Category_ID functions
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllByCategory_ID</para>
		/// <para>Input: Category_ID</para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAllByCategory_ID(int Category_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllByCategory_ID(Category_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDSByCategory_ID</para>
		/// <para>Input: Category_ID</para>
		/// <para>Output: NewsDataSet</para>
		///</summary>
		public DataSet SelectAllDSByCategory_ID(int Category_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDSByCategory_ID(Category_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllByCategory_ID</para>
		/// <para>Input: Category_ID</para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAllByCategory_IDFilter(string strFilter,int Category_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllByCategory_IDFilter(strFilter,Category_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDSByCategory_ID</para>
		/// <para>Input: Category_ID</para>
		/// <para>Output: NewsDataSet</para>
		///</summary>
		public DataSet SelectAllDSByCategory_IDFilter(string strFilter,int Category_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDSByCategory_IDFilter(strFilter,Category_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: DeleteByCategory_ID</para>
		/// <para>Input: Category_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool DeleteByCategory_ID(int Category_ID){
			NewsDAO dao = new NewsDAO();
			return dao.DeleteByCategory_ID(Category_ID);
		}
		#endregion

		#region Select,delete by User_ID functions
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllByUser_ID</para>
		/// <para>Input: User_ID</para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAllByUser_ID(int User_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllByUser_ID(User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDSByUser_ID</para>
		/// <para>Input: User_ID</para>
		/// <para>Output: NewsDataSet</para>
		///</summary>
		public DataSet SelectAllDSByUser_ID(int User_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDSByUser_ID(User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllByUser_ID</para>
		/// <para>Input: User_ID</para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAllByUser_IDFilter(string strFilter,int User_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllByUser_IDFilter(strFilter,User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDSByUser_ID</para>
		/// <para>Input: User_ID</para>
		/// <para>Output: NewsDataSet</para>
		///</summary>
		public DataSet SelectAllDSByUser_IDFilter(string strFilter,int User_ID){
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDSByUser_IDFilter(strFilter,User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: DeleteByUser_ID</para>
		/// <para>Input: User_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool DeleteByUser_ID(int User_ID){
			NewsDAO dao = new NewsDAO();
			return dao.DeleteByUser_ID(User_ID);
		}
		#endregion

		#region Select,Delete by Category_IDUser_ID
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllByCategory_IDUser_ID</para>
		/// <para>Input: Category_ID,User_ID</para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAllByCategory_IDUser_ID(int Category_ID,int User_ID)
		{
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllByCategory_IDUser_ID(Category_ID,User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDSByCategory_IDUser_ID</para>
		/// <para>Input: Category_ID,User_ID</para>
		/// <para>Output: DataSet</para>
		///</summary>
		public DataSet SelectAllDSByCategory_IDUser_ID(int Category_ID,int User_ID)
		{
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDSByCategory_IDUser_ID(Category_ID,User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllByCategory_IDUser_ID</para>
		/// <para>Input: Category_ID,User_ID</para>
		/// <para>Output: List of NewsEntity</para>
		///</summary>
		public List<NewsEntity> SelectAllByCategory_IDUser_IDFilter(string strFilter,int Category_ID,int User_ID)
		{
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllByCategory_IDUser_IDFilter(strFilter,Category_ID,User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: SelectAllDSByCategory_IDUser_ID</para>
		/// <para>Input: Category_ID,User_ID</para>
		/// <para>Output: DataSet</para>
		///</summary>
		public DataSet SelectAllDSByCategory_IDUser_IDFilter(string strFilter,int Category_ID,int User_ID)
		{
			NewsDAO dao = new NewsDAO();
			return dao.SelectAllDSByCategory_IDUser_IDFilter(strFilter,Category_ID,User_ID);
		}
		///<summary>
		/// <para>Author: Auto generated by CSharp Code Generator v2.0</para>
		/// <para>Date:28/09/2010 47:04:27</para>
		/// <para>Name: DeleteByCategory_IDUser_ID</para>
		/// <para>Input: Category_ID,User_ID</para>
		/// <para>Output: return true if succeeded else return false</para>
		///</summary>
		public bool DeleteByCategory_IDUser_ID(int Category_ID,int User_ID)
{
			NewsDAO dao = new NewsDAO();
			return dao.DeleteByCategory_IDUser_ID(Category_ID,User_ID);
		}
		#endregion
	}
	/*****************************************************************************************************/
	/**********************************END NewsWebServiceBase*****************************************/
	/*****************************************************************************************************/
}

